package com.yu1996.search.dao;

import com.yu1996.search.pojo.Article;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;

public interface ArticleDao extends ElasticsearchRepository<Article, String> {

    /**
     * @param title    标题
     * @param content  内容
     * @param pageable 分页
     * @return org.springframework.data.domain.Page<com.yu1996.search.pojo.Article>
     * @description 根据标题和内容搜索 + 分页
     * @date 2019/10/15 18:50
     */
    Page<Article> findByTitleOrContentLike(String title, String content, Pageable pageable);
}
